﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<IEnumerable<Fashion.Models.ProductCategory>>" %>
<div class="category radius-5px">
    <p class='title'>Danh mục sản phẩm</p>
    <ul class='nav-category'>
        <%foreach (var category in Model)
          {%>
        <li class='item-category'>
            <p>
                <%=category.Name %></p>
            <ul class='nav-subcategory'>
                <%foreach (var subCategory in category.ProductCategories.OrderBy(i => i.OrderDisplay))
                  {%>
                <li>
                    <%=Html.ActionLink(subCategory.Name, "Detail", "Category", new { id = subCategory.Id }, null)%></li>
                <%} %>
            </ul>
        </li>
        <%} %>
    </ul>
</div>
